<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        <input type="button" value="get" class="get">
        <input type="button" value="post" class="post">
        <p id="xxx"></p>
    </div>
    <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <script>
        document.querySelector(".get").onclick= function () { 
           axios.get("https://autumnfish.cn/api/joke/list?num=3").then(function(response){
                document.querySelector("#xxx").innerHTML=response.data;   
           },function(err){
               console.log(err)
           }) 

        document.querySelector(".post").onclick= function() {
            axios.post("https://autumnfish.cn/api/user/reg",{username:"jack"}).then(function(response){
                console.log(response);
            },function(err){
               console.log(err)
           })
        }   
        }
    </script>
    <script>
        var app = new Vue({
            el:"#app",
            data:{
                
            },
            methods: {
                
            },
        })
    </script>

</body>
</html>